home *** CD-ROM | disk | FTP | other *** search
/ Amiga Plus 1997 #2 / Amiga Plus CD - 1997 - No. 02.iso / demo-versionen / ess3000 / install_es3000 < prev    next >
Text File  |  1978-06-11  |  19KB  |  482 lines

  1. ;******************************************************************************
  2. ;      ______ ______ ____   ____   ____   ____
  3. ;     / ____// ____//___ \ / __ \ / __ \ / __ \
  4. ;    / /_   / /___   __/ // / / // / / // / / /
  5. ;   / __/  /___  /  /_  // / / // / / // / / /
  6. ;  / /___ ____/ / ___/ // /_/ // /_/ // /_/ /
  7. ; /_____//_____/ /____/ \____/ \____/ \____/
  8. ; Chinon ES-3000 Electronic Still Camera Software
  9. ;
  10. ; $VER: 1.0h_ES3000_Installer (April-16-1996) 
  11. ; Changes, suggestions or problems: rcr@netcom.com
  12. ;
  13. ; Installer Copyright ©1996 by Robert C. Reiswig  
  14. ; ES3000 Software Copyright ©1996 by Vision Factory Development, Frank Mariak
  15. ; Distributed by ML Computer, Im Ring 29, 47445 Moers, GERMANY
  16. ;******************************************************************************
  17.  
  18. ;*** System Stuff ***
  19. (set cpu (database "cpu"))  (set vblank (database "vblank"))
  20. (set graphmem (database "graphics-mem")) (set totmem (database "total-mem"))
  21. (set osver (/ (getversion "LIBS:version.library") 65536))
  22. (if (= vblank "60") ((set blank "NTSC")) ((set blank "PAL")))
  23. (set fastmem (- totmem graphmem))
  24.  
  25. (if (= osver 37) (set workbench "2.0")) (if (= osver 38) (set workbench "2.1"))
  26. (if (= osver 39) (set workbench "3.0")) (if (= osver 40) (set workbench "3.1"))
  27. (if (= osver 41) (set workbench "3.2"))
  28.  
  29. (set cpu (database "cpu"))
  30. (if (= cpu 68000) (set #cpu 0)) (if (= cpu 68010) (set #cpu 1))
  31. (if (= cpu 68020) (set #cpu 2)) (if (= cpu 68030) (set #cpu 3))
  32. (if (= cpu 68040) (set #cpu 4)) 
  33. (if (> (exists ("sys:libs/68060.library")) 0) (set #cpu 5) )
  34.  
  35. (if (> cpu 68010)  (set #fpuGuess 0)  (set #fpuGuess 1) )
  36.    
  37. (set vernum1 (getversion "ES3000"))
  38. (set ver1 (/ vernum1 65536)) (set rev1 (- vernum1 (* ver1 65536) ) )
  39. (set ES3000ver (cat ver1 "." rev1))
  40.  
  41. (if (> (exists ("env:Language")) 0) (set lanfound (getenv "Language")) )
  42. (set lan 0)
  43.  
  44. (if (= "english"    lanfound) (set lan 0))  (if (= "deutsch"    lanfound) (set lan 1))
  45.  
  46. (set mfound 0) (set newicon1 1) 
  47. (set keeper 1) (set firsttime 0)
  48.  
  49. (set #Compress "lhex")
  50. (set #untempdir "T:")
  51. (set #binarchivename "ES3000bin.lha")
  52.  
  53. ;********************************************************************
  54. ; English Strings
  55. ;********************************************************************
  56. (set #about (cat "\nWelcome to ES3000 AMIGA Image Receiver Utility 1.2 Demo for the Chinon ES-3000 Electronic Still Camera\n\nCopyright ©1996 by\nVision Factory Development\n\nDistributed by\nML Computer\nIm Ring 29\n47445 Moers\nGERMANY") )
  57. (set #whereES3000 "Where do you wish to install ES3000. A directory called 'ES3000' will be created if one is not there. If a copy of ES3000 is found it will be backed up.")
  58. (set #askfpu "\nIs there a 68881/68882 compatible floating point unit (FPU) installed on the machine that you are installing ES3000 on?\n")
  59. (set #compatible " or compatible")
  60. (set #nofpu "No FPU")
  61. (set #filethere1 "\n\nThe installer has found ES3000 version ")
  62. (set #filethere2 " at ")
  63. (set #filethere3 "\n\nThe file will be renamed to ")
  64. (set #filethere4 " and it will then be moved to ")
  65. (set #backuptoXXX "Back-UP to file named 'ES3000.")
  66. (set #copyover "Copy Over Old Version")
  67. (set #oktodelete1 "\nIs it ok to delete the older ES3000 binary so that the ES3000 Directory can be made?\n")
  68. (set #oktodelete2 "\nIs it ok to delete the older _renamed_ ES3000 binary so that the ES3000 Directory can be made?\n")
  69. (set #ES3000found "\nThe Installer has found a copy of ES3000 already installed. What do you want to do?\n")
  70. (set #uncompressingbin (cat "\n\nUncompressing the selected ES3000 binary to\n\n" #untempdir "ES3000"))
  71. (set #errorbin (cat "\n\nThe " #binarchivename " is missing or has an error in it. You might try to reinstall.  If that does not work you will need to get a new ES3000 disk/archive."))
  72. (set #newicon "\nDo you wish to copy over The ES3000 Icon from the archive? If you have any ToolTypes already set you should select no.\n")
  73. (set #nonewicon  "No  - ToolTypes already set.")
  74. (set #yesnewicon "Yes - Copy over Icon.")
  75. (set #notooltype  "No  - ToolTypes already set.")
  76. (set #yestooltype "Yes - Set ToolTypes.")
  77. (set #tooltype "\nWhat ToolTypes would you like to set?\n")
  78. (set #maxpens "Max # of pens for image previews")
  79. (set #savedct "File format for default save") 
  80. (set #dev-unit "Serial Port")
  81. (set #dev-baud "Baud Rate")
  82. (set #maxpensQ "\nWhich image file format should be used as default save format?\n\nDCT is an internal Chinon ES3000 standard format which has additional picture information within the file, while IFF24 is a widely spreaded image format which can be read by most AMIGA programs but can not be read back by the ES3000 program.\n")
  83. (set #savedctQ "\nWhat is the maximum number of pens which should be allocated for image previews?\n\nHere you can specify the maximum number of pens which should be used for image previews. If you open on a custom screen, set this to 256, if you open on a pubscreen you should try values between 16-32 to allow other programs allocating pens.\n")
  84. (set #serboard "\nWhat is the name of the Serial port (device) you wish to use?  ES3000 software defaults to using 'serial.device'\n")
  85. (set #otherboard "\nEnter the Serial Device you wish to use?\n")
  86. (set #serunit "\nWhat is the unit of the serial device to use?  Defaults is 0.\n")
  87. (set #serbaud "\nWhat is the Baud (bps) Rate you wish to use? The default is 19200.\n")
  88. (set #whatdocs "\nWhat ES3000 documentation would you like to install?\n")
  89. (set #wheredocs "Where would you like the ES3000 documentation you selected to be installed?")
  90. (set #whatexam "\nWould you like to install the Example picture files? They will be placed in ")
  91. (set #examsize1 ". There is about ")
  92. (set #examsize2 "K total of Example picture files.\n")
  93. (set #example1 " Example Pictures ")
  94. (set #byebye (cat "\nES3000 Install Complete!\n\n" ))
  95.  
  96. ;********************************************************************
  97. ; German Strings
  98. ;********************************************************************
  99. (if (= lan 1)
  100. (
  101. (set #about (cat "\nWillkommen zur Installation des ES3000 AMIGA Programms V1.2 Demo für die Chinon ES-3000 Kamera\n\nCopyright ©1996 by\nVision Factory Development\n\nVertrieb durch\nML Computer\nIm Ring 29\n47445 Moers\nGERMANY") )
  102. (set #whereES3000 "Wohin wollen Sie die ES3000 Software installieren. Ein Verzeichnis namens 'ES3000' wird dort erstellt, wenn es nicht bereits existiert. Wird eine bereits installierte Version gefunden, so wird diese gesichert.")
  103. (set #askfpu "\nIst eine 68881/68882 kompatible FPU in dem Rechner vorhanden, auf dem Sie dieses Programm verwenden wollen ?\n")
  104. (set #compatible " oder kompatibel")
  105. (set #nofpu "keine FPU vohanden")
  106. (set #filethere1 "\n\nIch habe das ES3000 Programm Version ")
  107. (set #filethere2 " gefunden in ")
  108. (set #filethere3 "\n\nDie Datei wird umbenannt in ")
  109. (set #filethere4 " und wird dann verschoben nach ")
  110. (set #backuptoXXX "Sichere in Datei namens 'ES3000.")
  111. (set #copyover "Überschreibe die alte Version")
  112. (set #oktodelete1 "\nIst es in Ordnung, das alte  ES3000 Programm zu löschen, so daß das ES3000 Verzeichnis erstellt werden kann ?\n")
  113. (set #oktodelete2 "\nIst es in Ordnung, das alte, _umbenannte_ ES3000 Programm zu löschen, so daß das ES3000 Verzeichnis erstellt werden kann ?\n")
  114. (set #ES3000found "\nIch habe eine Kopie des ES3000 Programms gefunden. Was soll ich tun?\n")
  115. (set #uncompressingbin (cat "\n\nEntpacke die gewählte ES3000 Datei nach\n\n" #untempdir "ES3000"))
  116. (set #errorbin (cat "\n\nDie Datei " #binarchivename " fehlt oder hat einen Fehler. Sie sollten den Installationsvorgang abbrechen.  Sie brauchen möglicherweise ein(e) neue(s) ES3000 Diskette/Archiv."))
  117. (set #newicon "\nWollen Sie das alte ES3000 Piktogramm überschreiben ? Wenn Sie bereits Programmmerkmale eingestellt haben, sollten Sie Nein wählen.\n")
  118. (set #nonewicon  "Nein  - Merkmale bereits gesetzt.")
  119. (set #yesnewicon "Ja - Überschreibe Piktogramm.")
  120. (set #notooltype  "Nein  - Merkmale bereits gesetzt.")
  121. (set #yestooltype "Ja - Setze Merkmale.")
  122. (set #tooltype "\nWelche Programmmerkmale möchten Sie setzen ?\n")
  123. (set #maxpens "Maximale # Farben für Image Vorschau")
  124. (set #savedct "Standard Dateiformat") 
  125. (set #dev-unit "Serieller Treiber")
  126. (set #dev-baud "Baud Rate")
  127. (set #maxpensQ "\nWelches Dateiformat soll standardmäßig genutzt werden ?\n\nDCT ist das interne Chinon ES3000 Standardformat, welches zusätzliche Bildinformationen abspeichert, während IFF24 ein weit verbreitetes Dateiformat ist, welches von vielen AMIGA Programmen gelesen werden kann, allerdings nicht vom ES3000 Programm.\n")
  128. (set #savedctQ "\nWieviel Farben sollen maximal für die Bildvorschau angelegt werden ?\n\nHier können Sie die maximale Farbzahl für angezeigte Bilddaten wählen. Wenn Sie einen neuen Schirm öffnen, wählen Sie 256.\n")
  129. (set #serboard "\nWie heißt der Treiber, an dem die Kamera benutzt werden soll ? ES3000 verwendet standardmäßig das 'serial.device'\n")
  130. (set #otherboard "\nGeben Sie den Schnittstellentreiber ein, den Sie verwenden wollen?\n")
  131. (set #serunit "\nWelche Schnittstelleneinheit wollen Sie verwenden ? Standard ist 0.\n")
  132. (set #serbaud "\nWelche Baudrate wollen Sie verwenden ? Standard ist 19200.\n")
  133. (set #whatdocs "\nWelche ES3000 Dokumentation wollen Sie installieren?\n")
  134. (set #wheredocs "Wohin wollen Sie die ES3000 Dokumentation, die Sie gewählt haben, installieren?")
  135. (set #whatexam "\nWollen Sie die Beispielbilddaten installieren? Sie werden abgelegt in ")
  136. (set #examsize1 ". Es sind ungefähr ")
  137. (set #examsize2 "K an Beispielbilddaten vorhanden.\n")
  138. (set #example1 " Beispieldaten ")
  139. (set #byebye (cat "\nES3000 Installation fertig!\n\n" ))
  140.  
  141.  
  142. )
  143. )
  144. ;********************************************************************
  145. ; Hello
  146. ;********************************************************************
  147. (message #about)
  148. (welcome) 
  149.  
  150. ;********************************************************************
  151. ; Ask where to put ES3000 & Make dir if needed
  152. ;********************************************************************
  153. (set ES3000dir  (askdir (prompt #whereES3000)
  154.                (help   #whereES3000)
  155.                     (default "Work:")
  156.                )  
  157. )
  158.  
  159. (set where ES3000dir)
  160.  
  161. ;********************************************************************
  162. ; Check on the FPU
  163. ;********************************************************************
  164. (set fpuPick (askchoice (choices (cat "68881/68882" #compatible) #nofpu)
  165.             (prompt #askfpu)
  166.                     (help   #askfpu)
  167.                   (default #fpuGuess)
  168.       )
  169. )
  170.  
  171. ;********************************************************************
  172. ; Check to see if ES3000 is already there, if so ask to backup
  173. ;********************************************************************
  174. (if (= 1 (exists (tackon where "ES3000") ) ) 
  175.   (
  176.     (set vernum1 (getversion (tackon where "ES3000") ))
  177.     (set ver1 (/ vernum1 65536)) (set rev1 (- vernum1 (* ver1 65536) ) )
  178.     (set ES3000_old (cat ver1 "." rev1))
  179.  
  180.     (message (cat #filethere1 ver1 "." rev1 #filethere2 where #filethere3 
  181.                   (cat "ES3000" ES3000_old) #filethere4 (tackon ES3000dir "ES3000") )
  182.     )
  183.     
  184.  
  185.     (copyfiles (source (tackon where "ES3000"))
  186.                (dest where) 
  187.                (infos)
  188.                (newname (cat "ES3000." ES3000_old))
  189.     )
  190.     
  191.     (delete (tackon ES3000dir "ES3000") (prompt #oktodelete1) (help #oktodelete1) (confirm) (infos)) 
  192.  
  193.     (if (< (exists (tackon ES3000dir "ES3000")) 2) (makedir (tackon ES3000dir "ES3000") (infos)) )    
  194.  
  195.     (copyfiles (source (tackon where (cat "ES3000." ES3000_old) ))
  196.                        (dest (tackon ES3000dir "ES3000")) 
  197.                        (infos)
  198.                
  199.     )
  200.  
  201.     (delete (tackon where (cat "ES3000" ES3000_old)) (prompt #oktodelete2) (help #oktodelete2) (confirm) (infos) ) 
  202.  
  203.     ;(set firsttime 1)
  204.  
  205.   )
  206. )
  207.  
  208. (if (< (exists (tackon ES3000dir "ES3000")) 2) (makedir (tackon ES3000dir "ES3000") (infos)) )
  209. (set where (tackon ES3000dir "ES3000"))
  210. (set @default-dest where)
  211.  
  212. ;********************************************************************
  213. ; Check for old & backup
  214. ;********************************************************************
  215. (if (exists (tackon where "ES3000")) 
  216.   (
  217.       (set vernum1 (getversion (tackon where "ES3000") ))
  218.       (set ver1 (/ vernum1 65536)) (set rev1 (- vernum1 (* ver1 65536) ) )
  219.       (set ES3000_old (cat ver1 "." rev1))
  220.  
  221.       (set keeper  (askchoice (choices  (cat #backuptoXXX ES3000_old "'")  #copyover)
  222.                      (prompt #ES3000found)
  223.                  (help   #ES3000found)
  224.                      (default 0)
  225.                )
  226.       )    
  227.  
  228.  
  229.       (if (= keeper 0)
  230.          (copyfiles (source (tackon where "ES3000"))
  231.                      (dest where) 
  232.                      (infos)
  233.                      (newname (cat "ES3000" ES3000_old))
  234.          )
  235.       )          
  236.  
  237.       (set firsttime 1)
  238.     
  239.   )
  240. )
  241.  
  242. ;********************************************************************
  243. ; Copy over correct ES3000 and Icon if wanted
  244. ;********************************************************************
  245. (if (= fpuPick 0)
  246.   (
  247.    (working (cat #uncompressingbin ".FPU"))
  248.    (set ToDo  ("%s \"-qfw=%s\" x %s %s" #Compress #untempdir #binarchivename "es3000.fpu")) 
  249.    (set error (run ToDo))
  250.    (if (= error 0)
  251.      (
  252.        (copyfiles (source (tackon #untempdir "ES3000.FPU")) (dest where) (optional "nofail") (newname "ES3000") )
  253.        (delete (tackon #untempdir "ES3000.FPU"))
  254.      )
  255.  
  256.      (message #errorbin)
  257.    )
  258.  
  259.   )
  260.  
  261.  
  262.  
  263.   (
  264.    (working (cat #uncompressingbin ""))
  265.    (set ToDo  ("%s \"-qfw=%s\" x %s %s" #Compress #untempdir #binarchivename "es3000")) 
  266.    (set error (run ToDo))
  267.    (if (= error 0) 
  268.     (
  269.        (copyfiles (source (tackon #untempdir "ES3000")) (dest where) (optional "nofail") (newname "ES3000") )
  270.        (delete (tackon #untempdir "ES3000"))      
  271.     )
  272.  
  273.     (message #errorbin)  
  274.  
  275.    )
  276.   )
  277. )
  278.  
  279. (if (= firsttime 0)  (copyfiles (source "icons/ES3000.info") (dest where) (optional "nofail") ) )
  280.  
  281.  
  282. (if (OR (= keeper 0) (= (exists (tackon where "icons/ES3000.info")) 0))
  283.   (
  284.   
  285.    (set newicon (askchoice (choices #yesnewicon #nonewicon)
  286.                            (prompt #newicon)
  287.                        (help   #newicon)
  288.                            (default 0)
  289.             )
  290.    )
  291.   
  292.    (if (= newicon 0) 
  293.      (copyfiles (source "icons/ES3000.info") (dest where)  (optional "nofail") )
  294.    )
  295.  
  296.   )
  297.  
  298. )
  299.  
  300. ;********************************************************************
  301. ; Ask to Set ToolTypes
  302. ;********************************************************************
  303. (set tooltypes (askoptions  (choices (cat " MAXPENS - " #maxpens) (cat " SAVEDCT - " #savedct)
  304.                                      (cat " DEVICE_NAME & DEVICE_UNIT - " #dev-unit)
  305.                                      (cat " DEVICE_BAUD - " #dev-baud)
  306.                             )
  307.                             (prompt #tooltype)
  308.                         (help   #tooltype)
  309.                             (default 15)
  310.                )
  311. )
  312.  
  313. (if (IN tooltypes 0)
  314.  (
  315.    (set maxpens (asknumber (prompt #savedctQ)
  316.                        (help   #savedctQ)
  317.                            (default 256)
  318.                 )
  319.    ) 
  320.   
  321.    (tooltype (dest (tackon where "ES3000")) 
  322.              (settooltype "MAXPENS" (cat maxpens))
  323.    )
  324.  
  325.  )
  326. )
  327.  
  328.  
  329. (if (IN tooltypes 1)
  330.  (
  331.    (set savedct (askchoice (choices " DCT" " IFF24")
  332.                            (prompt #maxpensQ)
  333.                        (help   #maxpensQ)
  334.                            (default 1)
  335.                 )
  336.    ) 
  337.  
  338.    (tooltype (dest (tackon where "ES3000"))
  339.              (if (= savedct 0) (settooltype "SAVEDCT" "YES") )
  340.              (if (= savedct 1) (settooltype "SAVEDCT" "NO") )
  341.         
  342.    )
  343.  )
  344.  
  345. )  
  346.  
  347.  
  348. (if (IN tooltypes 2)
  349.  (
  350.    (set device (askchoice (choices "serial.device" "gvpser.device" "duart.device" "hattser.device" "Other")
  351.                 (prompt #serboard)
  352.             (help   #serboard)
  353.                 (default 0)
  354.            )
  355.    ) 
  356.  
  357.    (if (= device 0) (set device "serial.device"))
  358.    (if (= device 1) (set device "gvpser.device"))
  359.    (if (= device 2) (set device "duart.device"))
  360.    (if (= device 3) (set device "hattser.device"))
  361.           
  362.    (if (= device 4)
  363.      (
  364.       (set device  (askstring 
  365.                      (prompt #otherboard)
  366.                      (help   #otherboard)
  367.                      (default ".device")
  368.                )
  369.       )
  370.      )
  371.    )
  372.  
  373.  
  374.    (set unit (askchoice (choices "0" "1" "2" "3" "4" "5" "6" "7" "8")
  375.               (prompt #serunit)
  376.               (help   #serunit)
  377.               (default 0)
  378.              )
  379.    )  
  380.  
  381.    
  382.    (tooltype (dest (tackon where "ES3000")) 
  383.              (settooltype "DEVICE_NAME" (cat device))
  384.              (settooltype "DEVICE_UNIT" (cat unit))
  385.    )
  386.  
  387.  
  388.  )
  389. )
  390.   
  391.  
  392. (if (IN tooltypes 3)
  393.  ( 
  394.   (set baud (askchoice (choices "9600" "19200" "38400" "57600" "115200")
  395.                         (prompt #serbaud)
  396.                     (help   #serbaud)
  397.                         (default 1)
  398.              )
  399.   ) 
  400.  
  401.   (if (= baud 0) (set baud "9600"))    (if (= baud 1) (set baud "19200"))
  402.   (if (= baud 2) (set baud "38400"))   (if (= baud 3) (set baud "57600"))
  403.   (if (= baud 4) (set baud "115200")) 
  404.  
  405.   (tooltype (dest (tackon where "ES3000")) 
  406.             (settooltype "DEVICE_BAUD" (cat baud))
  407.   )
  408.  
  409.  
  410.  )
  411. )
  412.  
  413.  
  414. ;********************************************************************
  415. ; Ask and copy Examples if wanted!
  416. ;********************************************************************
  417. (set size 0)
  418. (foreach "Examples" "#?.dct"  (set size (+ size (getsize (tackon "Examples" @each-name)))) )
  419. (set sizek (/ size 1024))
  420.  
  421.  
  422. (set exam (askoptions (choices (cat #example1 " (" sizek "K)") )
  423.               (prompt (cat #whatexam (tackon where "Examples") #examsize1 sizek #examsize2) )
  424.                       (help   (cat #whatexam (tackon where "Examples") #examsize1 sizek #examsize2) )
  425.                   (default 1)
  426.       )
  427. )
  428.  
  429.  
  430. (if (<> exam 0)
  431.  (
  432.    (set examdir (tackon where "Examples"))
  433.    (if (< (exists examdir) 2) (makedir examdir)  )
  434.  
  435.    (if (IN exam 0)
  436.     (
  437.      (foreach "Examples" "#?.dct"
  438.        (copyfiles (source (tackon "Examples" @each-name)) (dest examdir) (infos) (optional "nofail") ) 
  439.      )
  440.     )
  441.    )
  442.  
  443.  )
  444. )
  445.  
  446.  
  447. ;********************************************************************
  448. ; Ask and copy docs if wanted!
  449. ;********************************************************************
  450. (set docs (askoptions (choices " Readme")
  451.               (prompt #whatdocs)
  452.                       (help #whatdocs)
  453.                   (default 1)
  454.       )
  455. )
  456.  
  457. (if (<> docs 0)
  458.  (
  459.    (set docsdir (askdir (prompt #wheredocs)
  460.                (help   #wheredocs)
  461.                     (default where)
  462.                 )  
  463.    )
  464.  
  465.    (if (IN docs 0) (copyfiles (source "ReadMe") (dest docsdir) (infos) (optional "nofail") ) )
  466.    
  467.  )
  468. )
  469.  
  470. ;********************************************************************
  471. ; Copy or Update gtlayout.library
  472. ;********************************************************************
  473. (foreach "libs" "#?.library"
  474.   (copylib (source (tackon "libs" @each-name)) (dest "libs:") (optional "nofail") ) 
  475. )
  476.  
  477.  
  478. ;********************************************************************
  479. ; End Bye 
  480. ;********************************************************************
  481. (exit #byebye)
  482.